package cn.song.service;

import cn.song.domain.ProductInfo;
import cn.song.dto.CardDto;
import cn.song.enums.ProductStatus;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

public interface ProductService {

    ProductInfo save (ProductInfo pro);

    Page<ProductInfo> findAll(Pageable pageable);

    List<ProductInfo> findUpAll();

    ProductInfo findById(String id);

    //加库存
    void increaseStock(List<CardDto> cartDTOList);

    //减库存
    void decreaseStock(List<CardDto> cartDTOList);


}
